<?php $this->dojo()->enable()
             ->setDjConfigOption('parseOnLoad', true)
             //->setDjConfigOption('isDebug', true)
             ->requireModule('dojo.parser')
             ->requireModule('dojox.grid.Grid'); ?>


<style type="text/css">
  @import "http://dojocampus.org/dojotoolkit/dojox/grid/_grid/Grid.css";
/*  @import "http://dojocampus.org/dojotoolkit/dojox/grid/_grid/nihiloGrid.css"; */

  #grid1 {
  	height:400px;
  	width:900px;
  }

</style>

<!-- script type="text/javascript" src="/dojotoolkit/dojox/grid/tests/support/test_data.js" -->
<script type="text/javascript">
	// example sample data and code
	// some sample data
	// global var "data"
	data = [
		[ "normal", false, "new", 'But are not followed by two hexadecimal', 29.91, 10, false ],
		[ "important", false, "new", 'Because a % sign always indicates', 9.33, -5, false ],
		[ "important", false, "read", 'Signs can be selectively', 19.34, 0, true ],
		[ "note", false, "read", 'However the reserved characters', 15.63, 0, true ],
		[ "normal", false, "replied", 'It is therefore necessary', 24.22, 5.50, true ],
		[ "important", false, "replied", 'To problems of corruption by', 9.12, -3, true ],
		[ "note", false, "replied", 'Which would simply be awkward in', 12.15, -4, false ]
	];
	var rows = 100;
	for(var i=0, l=data.length; i<rows-l; i++){
		data.push(data[i%l].slice(0));
	}

	// global var "model"
	model = new dojox.grid.data.Table(null, data);

	/*
	// simple display of row info; based on model observation
	// global var "modelChange"
	modelChange = function(){
		var n = dojo.byId('rowCount');
		if(n){
			n.innerHTML = Number(model.getRowCount()) + ' row(s)';
		}
	}
	*/
</script>
<script type="text/javascript">
    // a grid view is a group of columns
    var view1 = {
      cells: [[
        {name: 'Column 0'}, {name: 'Column 1'}, {name: 'Column 2'}, {name: 'Column 3', width: "20%"}, {name: 'Column 4'}, {name: 'Column 5'}, {name: 'Column 6'}
      ]]
    };
    // a grid layout is an array of views.
    var layout = [ view1 ];
</script>

<div id="grid1" dojoType="dojox.Grid" model="model" structure="layout"></div>